//
//  SEExamineEntranceCell.swift
//  SmartEyeForPatient
//
//  Created by qdsg on 2021/4/8.
//

import UIKit

class SEExamineEntranceCell: UITableViewCell {

    var examineEntranceCellTapClosure: ((_ type: SEExamineEntranceBtnViewType) -> Void)?

    static let className = "SEExamineEntranceCell"
    static let reuseId = className

    @IBOutlet var entranceBtns: [SEExamineEntranceBtnView]! {
        didSet {
            entranceBtns.forEach {
                let tag = $0.tag
                $0.viewType = SEExamineEntranceBtnViewType(rawValue: tag) ?? .reserve
                $0.examineEntranceBtnViewTapClosure = { [weak self] viewType in
                    self?.examineEntranceCellTapClosure?(viewType)
                }
            }
        }
    }

    override func awakeFromNib() {
        super.awakeFromNib()
        // Initialization code
    }

    override func setSelected(_ selected: Bool, animated: Bool) {
        super.setSelected(selected, animated: animated)

        // Configure the view for the selected state
    }
    
}
